<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Final//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=Windows-1252">
<TITLE>OpenPrint, AbortPrint, and ClosePrint Methods</TITLE>
<link rel="stylesheet" type="text/css" href="help.css">
</HEAD>

<BODY BGCOLOR="#FFFFFF" TEXT="#000000">

<OBJECT TYPE="application/x-oleobject" CLASSID="clsid:1e2a7bd0-dab9-11d0-b93a-00c04fc99f9e">
	<PARAM NAME="Keyword" VALUE="AbortPrint">
	<PARAM NAME="Keyword" VALUE="ClosePrint">
	<PARAM NAME="Keyword" VALUE="OpenPrint">
	<PARAM NAME="Keyword" VALUE="Printing">
</OBJECT>

<H1><A NAME="openprint__abortprint__and_closeprint_methods"></A><B>OpenPrint, AbortPrint, and ClosePrint Methods</B></H1>
<HR>

<H2 class="AppliesTo">Applies to</H2>

<P><A HREF="thtmlviewer_component.htm">THtmlViewer</A> component</P>

<P><B>Declarations</B></P>

<P>procedure OpenPrint;</P>

<P>procedure AbortPrint;</P>

<P>procedure ClosePrint;</P>

<H2 class="Description">Description</H2>

<P>For most printing situations, these methods would not be used as a simple call to the <A HREF="print_method.htm"><B>Print</B> method</A> but be sufficient.  However, these methods might prove useful when it is desired to print several odd pages of a document or to even make changes in the document between portions printed.</P>

<P>Once <B>OpenPrint</B> is called, the printer will remain open until <B>ClosePrint</B> (or <B>AbortPrint</B>) is called.  While open, the <A HREF="print_method.htm"><B>Print </B>method</A> may be called successively to print various portions of the document.</P>

<P><B>AbortPrint</B> is provided to close the printer and cancel any portions not yet printed.</P>

<H2 class="Example">Example</H2>

<P>Viewer.OpenPrint;</P>

<P>Viewer.Print(1, 1);</P>

<P>Viewer.Print(22, 24);</P>

<P>Viewer.ClosePrint;</P>

</BODY>
</HTML>
